<template>
	<view class="beijingse">
		<view class="mainpadding">
			<template v-if="personInfo.shopapply.status==1">
				<!-- 审核中 -->
				<view class="icon">
					<image src="../../static/image/system/shz.png" mode=""></image>
				</view>
				<view class="margin_top4 textcenter huisetext">工作人员将会在3个工作日内审核您的提交， 审核通过将会给您生成后台管理账号密码， 如果审核未通过资金将原路返回，
					请留意此页面！</view>
			</template>
			<template v-if="personInfo.shopapply.status==2">
				<!-- 审核通过 -->
				<view class="icon">
					<image src="../../static/image/system/tg.png" mode=""></image>
				</view>
				<view class="block2 mainpadding ffffff">
					<view class=" textcenter huisetext">恭喜您，您已经通过审核！</view>
					<view class="heisetext textcenter margin_top">账号：{{personInfo.shopapply.account}}</view>
					<view class="heisetext textcenter margin_top1"> 密码：{{personInfo.shopapply.password}} </view>
					<view class="heisetext textcenter margin_top1">后台链接：{{personInfo.shopapply.pt_url}}</view>
				</view>
			</template>
			<template v-if="personInfo.shopapply.status==3">
				<!-- 审核不通过 -->
				<view class="icon">
					<image src="../../static/image/system/btg.png" mode=""></image>
				</view>
				<view class="block3 margin_top4">
					<view class="textcenter huisetext">很遗憾，您没有通过审核!</view>
					<view class="flexcenter">
						<view class="huisetext">如有疑问？</view>
						<view class="chengsetext" @click="phone(kf_mobile)">联系客服</view>
					</view>
					<view class="mainpadding ffffff radius margin_top4">
						<view class="bigbtext">失败原因：{{personInfo.shopapply.sh_bz}}</view>
					</view>
				</view>
			</template>
		</view>
		<view class="gudingdb" @click="jumpurl" v-if="personInfo.shopapply.status==3">
			<view class="bigbtn" >重新提交</view>
		</view>
	</view>
</template>

<script>
	const httpRequest = require("@/common/httpRequest.js")
	export default {
		data() {
			return {
				kf_mobile: "",
				personInfo: {
					shopapply: {
						status: "",
						sh_bz: "",
						account: "",
						password: "",
						pt_url: "",
					}
				},
			}
		},
		onShow() {
			this.init()
			this.getphone()
		},
		methods: {
			init() {
				httpRequest.request('/api/user/index', 'POST', {}, false, false, true).then(res => {
					if (res.code == 1) {
						this.personInfo = res.data
					}
				}).catch(err => {
					httpRequest.toast(err.msg);
				})
			},
			getphone() {
				httpRequest.request('/api/index/getConfigInfo', 'POST', {}, false, false, true).then(res => {
					if (res.code == 1) {
						this.kf_mobile = res.data.kf_mobile
					}
				}).catch(err => {
					httpRequest.toast(err.msg);
				})
			},
			phone(p) {
				uni.makePhoneCall({
					phoneNumber: p.toString()
				}).catch((e) => {
					// console.log(e)  //用catch(e)来捕获错误{makePhoneCall:fail cancel}
				})
			},
			jumpurl(){
				uni.navigateTo({
					url: '/pages/mypage/shangjrz'
				})
			},
		}
	}
</script>

<style lang="scss" scoped>
	.dianhua {
		font-size: 32rpx;
		font-family: PingFang SC-Medium, PingFang SC;
		font-weight: 500;
		color: #FFFFFF;
	}

	.chengsetext {
		font-size: 28rpx;
		font-family: PingFang SC-Medium, PingFang SC;
		font-weight: 500;
		color: #EF8933;
	}

	.heisetext {
		font-size: 28rpx;
		font-family: PingFang SC-Heavy, PingFang SC;
		font-weight: 800;
		color: #000000;
	}

	.huisetext {
		font-size: 28rpx;
		font-family: PingFang SC-Medium, PingFang SC;
		font-weight: 500;
		color: #999999;
	}

	.icon {
		margin: 30rpx auto 0;
		width: 274rpx;
		height: 274rpx;

		image {
			width: 100%;
			height: 100%;
		}
	}

	// .bddh {
	// 	width: 397rpx;
	// 	height: 64rpx;
	// 	display: flex;
	// 	margin: 50rpx auto 0;
	// 	align-items: center;
	// 	justify-content: center;
	// 	background-image: url('../../static/image/system/bdkfdh.png');
	// 	background-size: 100% 100%;
	// }

	.eshiliu {
		font-size: 26rpx;
		font-family: PingFang SC-Medium, PingFang SC;
		font-weight: 500;
		color: #666666;
	}

	.erwm {
		width: 243rpx;
		height: 243rpx;
		margin: 30rpx auto 0;

		image {
			width: 100%;
			height: 100%;
		}
	}

	.neijianju {
		padding: 0 130rpx;
	}

	.tkbox {
		padding-bottom: 60rpx;
	}

	// .tanktb {
	// 	width: 100%;
	// 	height: 237rpx;
	// 	background-size: 100% 100%;
	// 	background-image: url('../../static/image/system/tktb.png');
	// }
</style>
